package com.dhwl.hsh.driver.dto;

import android.os.Parcel;
import android.os.Parcelable;

import java.io.Serializable;

/**
 * 简要描述
 *
 * @author Derek.Kidd
 * @version V1.0.0
 * @date 2016-04-25 16:22
 */
public class Address implements Serializable, Parcelable {


    int addressType;
    String address;
    String name;
    String phone;

    public int getAddressType() {
        return addressType;
    }

    public void setAddressType(int addressType) {
        this.addressType = addressType;
    }

    public String getAddress() {
        return address;
    }

    public void setAddress(String address) {
        this.address = address;
    }

    public String getName() {
        return name;
    }

    public void setName(String name) {
        this.name = name;
    }

    public String getPhone() {
        return phone;
    }

    public void setPhone(String phone) {
        this.phone = phone;
    }

    @Override
    public int describeContents() {
        return 0;
    }

    @Override
    public void writeToParcel(Parcel dest, int flags) {
        dest.writeInt(this.addressType);
        dest.writeString(this.address);
        dest.writeString(this.name);
        dest.writeString(this.phone);
    }

    public Address() {
    }

    protected Address(Parcel in) {
        this.addressType = in.readInt();
        this.address = in.readString();
        this.name = in.readString();
        this.phone = in.readString();
    }

    public static final Parcelable.Creator<Address> CREATOR = new Parcelable.Creator<Address>() {
        @Override
        public Address createFromParcel(Parcel source) {
            return new Address(source);
        }

        @Override
        public Address[] newArray(int size) {
            return new Address[size];
        }
    };
}
